package com.neusoft.elmboot.mapper;

import java.util.List;

import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Update;

import com.neusoft.elmboot.po.Orders;
import org.apache.ibatis.annotations.Select;

@Mapper
public interface OrdersMapper {
	
	public Orders getOrdersById(Integer orderId);

	public List<Orders> listOrdersByUserId(String userId);

	public void saveOrders(Orders orders);


	Integer pay(Integer orderId);
	
	@Update("Update orders set consumedPoint=#{consumedPoint} where orderId=#{orderId}")
	int updateConsumedPointByorderId(int orderId,int consumedPoint);
	
}
